
<div style="display:{{$message_display}};float:left;clear:both; background:#f00; color:#fff; padding:2px 4px;">{{$message}}</div>
<form style="clear:both;" class="area" method="post" action="javascript:void(0)" onsubmit="submitForm(this,'cenovnik.php','POST','setContent')">
	
	<input type="hidden" name="a" value="cenovnici" />
	<input type="hidden" name="mod" value="new" />

	<h3 class="novi">novi cenovnik</h3>
	
	<label class="left" for="new_cenovnik_date">Datum:</label>
	<input type="text" name="new_cenovnik_date" id="new_cenovnik_date" maxlength="10" style="width:60px;" />
	<input type="button" class="datePicker" onclick="displayDatePicker('new_cenovnik_date',this)" />
	<input type="submit" value="sačuvaj" class="save" />
</form>
<div class="area" style="margin-left:2px;">
	<input type="button" value="osveži" class="refresh" onclick="LoadRSDoc('cenovnik.php?a=cenovnici','setContent')" /><br clear="all" />
	<table>
		<tr class="head" align="center">
			<td>šifra</td>
			<td>datum</td>
			<td></td>
		</tr>
		{{%loop start id}}
		<tr>
			<td>{{$id}}</td>
			<td>{{$date}}</td>
			<td>
				<input type="button" value="obriši" class="delete" onclick="if(confirm('Potvrdite brisanje cenovnika #{{$id}}.')){LoadRSDoc('cenovnik.php?a=cenovnici&mod=delete&id={{$id}}&date={{$date}}','setContent')}" />
				<input type="button" value="izmeni" class="edit" />
			</td>
		</tr>
		{{%loop end}}
	</table>
</div>